ci: Extend FAH rootfs for installed tests
authorColin Walters <walters@verbum.org>
Mon, 8 May 2017 20:44:42 +0000 (16:44 -0400)
committerAtomic Bot <atomic-devel@projectatomic.io>
Tue, 9 May 2017 15:08:26 +0000 (15:08 +0000)
These at the moment aren't in a container, and may need space. In the future
overlay2 will help here, we can more easily extend the rootfs.

Closes: #840
Approved by: jlebon

.redhat-ci.yml
tests/installed/fah-prep.sh [new file with mode: 0755]

index 818a072a86a22476ec4d538447b2391b7d15bc03..e3eb0f8738b540e5225a77b8303708bcdce877b0 100644 (file)
@@ -132,7 +132,7 @@ build:
 tests:
   - make install DESTDIR=$(pwd)/insttree
   - rsync -rl -e 'ssh -o User=root' . vmcheck:ostree/
-  - ssh root@vmcheck 'ostree admin unlock && rsync -rlv ./ostree/insttree/usr/ /usr/ && ./ostree/tests/installed/run.sh'
+  - ssh root@vmcheck './ostree/tests/installed/fah-prep.sh && ostree admin unlock && rsync -rlv ./ostree/insttree/usr/ /usr/ && ./ostree/tests/installed/run.sh'
 
 artifacts:
   - test-suite.log
diff --git a/tests/installed/fah-prep.sh b/tests/installed/fah-prep.sh
new file mode 100755 (executable)
index 0000000..0db4d15
--- /dev/null
@@ -0,0 +1,8 @@
+#!/bin/bash
+set -xeuo pipefail
+# If we're using devmapper, expand the root
+if lvm lvs atomicos/docker-pool &>/dev/null; then
+    systemctl stop docker
+    lvm lvremove -f atomicos/docker-pool
+fi
+lvm lvextend -r -l +100%FREE atomicos/root